<%@ Page Language="vb" EnableViewState="true" AutoEventWireup="false" Codebehind="SirketYetkilisi_Define.aspx.vb" Inherits="ccapps.Web.page.SirketYetkilisi_Define" codePage="65001" %>

<script language="javascript">var ob_tree_id="tree1";var ob_icons="/ccapps/TreeIcons/Icons";var ob_style="/ccapps/TreeIcons/Styles/Classic";ob_tree_editnode_enable=false;ob_tree_keynav_enable=false;ob_tree_multiselect_enable=false;ob_expand_single=false;verdadero=true;falso=false;wahr=true;falsch=false;vrai=true;faux=false;</script>
<script language="JavaScript" src="/ccapps/TreeIcons/Icons/ob_tree_504.js" type="text/javascript"></script>
<script language="JavaScript">
    

function check_list_checked() {
	// Make string with checked checkboxes IDs.
	
	document.getElementById('reasoncode').value=document.getElementById('reason').value;
	
	
	var ob_t2in,ob_t2s,ob_t2checked="";
	
	//if (check_list_kontrol()){	
	
	ob_t2in=document.getElementsByTagName("input");
	
	for (var i=0; i<ob_t2in.length; i++) {
		
		ob_t2s=ob_t2in[i].id;		
		if ((ob_t2s.substr(0,3)=="chk") && (ob_t2in[i].checked)) {		
			if (ob_t2checked==""){
			ob_t2checked=ob_t2checked+ob_t2in[i].value;
			}else{
			ob_t2checked=ob_t2checked+"|"+ob_t2in[i].value;
			}
		}
	}	
	//}else{
	//ob_t2checked="0";
	//}
	
	return ob_t2checked;
	
}

function check_list_kontrol() {
	// Make string with checked checkboxes IDs.
	
	var ob_t2in,ob_t2s,ob_t2checked="";
	var kontrol1=0;
	var kontrol2=0;
	var kontrol=0;
	ob_t2in=document.getElementsByTagName("input");
	
	for (var i=0; i<ob_t2in.length; i++) {
		
		ob_t2s=ob_t2in[i].id;		
		if (ob_t2s.substr(0,3)=="chk"){
			if ( ob_t2in[i].checked) {		
			kontrol1=kontrol1+1;
			}
			if (ob_t2in[i].disabled==true ) {		
			kontrol2=kontrol2+1;
			}
			kontrol=kontrol+1;
		}
		
	}	
		if (kontrol>(kontrol1+kontrol2)){
		//	alert ("Seзilebilecek tьm MSISDN leri seзmelisiniz !");
			
			return false;
		}else{
			return true;
		}
}



function check_all(obj) {
	// Make string with checked checkboxes IDs.
	
	var ob_t2in,ob_t2s,ob_t2checked="";
	ob_t2in=document.getElementsByTagName("input");
	
	for (var i=0; i<ob_t2in.length; i++) {
		
		ob_t2s=ob_t2in[i].id;		
		if ((ob_t2s.substr(0,3)=="chk")) {		
			if (obj.checked){
			if (ob_t2in[i].disabled==false){ob_t2in[i].checked=true;}
			}else{
			ob_t2in[i].checked=false;
			}
		}
	}	
	
	return ob_t2checked;
}

	
	
}

</script>
<form id="Form1" method="post" runat="server">
	<input id="proc" type="hidden" name="proc" runat="server"> <input id="Txt1" type="hidden" name="Txt1" runat="server">
	<input id="custcode" type="hidden" name="Txt1" runat="server"> <input id="statu" type="hidden" name="statu" runat="server">
	<input id="reasoncode" type="hidden" name="reasoncode" runat="server"> <input id="custtype" type="hidden" name="Txt1" runat="server">
	<table id="Table1" cellSpacing="0" cellPadding="0" width="100%" border="0">
		<tr>
			<TD class="solbaslik" vAlign="top">Custcode</TD>
			<TD class="input" vAlign="top"><b><asp:textbox id="customer" tabIndex="2" runat="server" Font-Bold="True" readonly="true" BackColor="#C0C0FF"
						width="150"></asp:textbox></b></TD>
		</tr>
		<tr>
			<TD class="solbaslik" vAlign="top">Sirket Adi</TD>
			<TD class="input" vAlign="top"><b><asp:textbox id="companyName" tabIndex="2" runat="server" Font-Bold="True" readonly="true" BackColor="#C0C0FF"
						width="400"></asp:textbox></b></TD>
		</tr>
		
	</table>
	<br>
	<TABLE id="Table2" cellSpacing="0" cellPadding="0" width="100%" border="0">
	<tr>
		<td>
			
			<asp:datagrid id="data_yetkili" runat="server" 
				AllowPaging="True" BorderColor="BurlyWood" AutoGenerateColumns="False" Height="20px"
				Font-Size="10px" Width="100%" PageSize="50">
				<SelectedItemStyle Wrap="False"></SelectedItemStyle>
				<EditItemStyle Wrap="False"></EditItemStyle>
				<AlternatingItemStyle Font-Size="11px" Wrap="False" HorizontalAlign="Center" ForeColor="DarkBlue" BackColor="LightGray"></AlternatingItemStyle>
				<ItemStyle Font-Size="11px" Font-Names="Verdana" Wrap="False" HorizontalAlign="Center" ForeColor="DarkBlue"
					BackColor="WhiteSmoke"></ItemStyle>
				<HeaderStyle Font-Size="10pt" Font-Names="Verdana" Font-Bold="True" HorizontalAlign="Center"
					ForeColor="White" BackColor="MediumPurple"></HeaderStyle>
				<Columns>
					<asp:TemplateColumn>
						<HeaderStyle ForeColor="White" BackColor="#A2547F"></HeaderStyle>
						<HeaderTemplate>
Msisdn
</HeaderTemplate>
						<ItemTemplate>
							<%# DataBinder.Eval(Container.DataItem,"msisdn") %>
						</ItemTemplate>
					</asp:TemplateColumn>
					<asp:TemplateColumn>
						<HeaderStyle ForeColor="White" BackColor="#A2547F"></HeaderStyle>
						<HeaderTemplate>
Kontrat No
</HeaderTemplate>
						<ItemTemplate>
							<%# DataBinder.Eval(Container.DataItem,"co_id") %>
						</ItemTemplate>
					</asp:TemplateColumn>
					<asp:TemplateColumn>
						<HeaderStyle ForeColor="White" BackColor="#A2547F"></HeaderStyle>
						<HeaderTemplate>
Şirket Yetkilisi</HeaderTemplate>
						<ItemTemplate>
							<%# DataBinder.Eval(Container.DataItem,"isim") %>
						</ItemTemplate>
					</asp:TemplateColumn>
					<asp:TemplateColumn>
						<HeaderStyle ForeColor="White" BackColor="#A2547F"></HeaderStyle>
						<HeaderTemplate>
yetkili_statu</HeaderTemplate>
						<ItemTemplate>
							<%# DataBinder.Eval(Container.DataItem,"servis_statu") %>
						</ItemTemplate>
					</asp:TemplateColumn>
				</Columns>
				
			</asp:datagrid></td>
	</tr>
	</table>
	<br>
	<TABLE id="Table2" cellSpacing="0" cellPadding="0" width="100%" border="0">
		<tr>
			<td><input class="c" onclick="check_all(this);" type="checkbox" name="ck">Hepsini 
				Seз</td>
		</tr>
		<tr>
			<td>
				<script>var i=0;</script>
				<asp:datagrid id="retantion_activate" runat="server" PagerStyle-HorizontalAlign="Center" OnPageIndexChanged="MyDataGrid_Page"
					AllowPaging="True" PageSize="50" BorderColor="BurlyWood" AutoGenerateColumns="False" Height="20px"
					Font-Size="10px" Width="100%" OnItemDataBound="ItemEventHandler">
					<SelectedItemStyle Wrap="False"></SelectedItemStyle>
					<EditItemStyle Wrap="False"></EditItemStyle>
					<AlternatingItemStyle Font-Size="11px" Wrap="False" HorizontalAlign="Center" ForeColor="DarkBlue" BackColor="LightGray"></AlternatingItemStyle>
					<ItemStyle Font-Size="11px" Font-Names="Verdana" Wrap="False" HorizontalAlign="Center" ForeColor="DarkBlue"
						BackColor="WhiteSmoke"></ItemStyle>
					<HeaderStyle Font-Size="10pt" Font-Names="Verdana" Font-Bold="True" HorizontalAlign="Center"
						ForeColor="White" BackColor="MediumPurple"></HeaderStyle>
					<Columns>
						<asp:TemplateColumn>
							<HeaderStyle ForeColor="White" BackColor="#A2547F"></HeaderStyle>
							<HeaderTemplate>
Seз
</HeaderTemplate>
							<ItemTemplate>

							</ItemTemplate>
						</asp:TemplateColumn>
						<asp:TemplateColumn>
							<HeaderStyle ForeColor="White" BackColor="#A2547F"></HeaderStyle>
							<HeaderTemplate>
Kontrat No
</HeaderTemplate>
							<ItemTemplate>
								<%# DataBinder.Eval(Container.DataItem,"co_id") %>
							</ItemTemplate>
						</asp:TemplateColumn>
						<asp:TemplateColumn>
							<HeaderStyle ForeColor="White" BackColor="#A2547F"></HeaderStyle>
							<HeaderTemplate>
Msisdn
</HeaderTemplate>
							<ItemTemplate>
								<%# DataBinder.Eval(Container.DataItem,"ms") %>
							</ItemTemplate>
						</asp:TemplateColumn>
						<asp:TemplateColumn>
							<HeaderStyle ForeColor="White" BackColor="#A2547F"></HeaderStyle>
							<HeaderTemplate>
Statu</HeaderTemplate>
							<ItemTemplate>
								<%# DataBinder.Eval(Container.DataItem,"statu") %>
							</ItemTemplate>
						</asp:TemplateColumn>
						
						
					</Columns>
					<PagerStyle NextPageText="ileri" Font-Size="Medium" Font-Bold="True" PrevPageText="geri" HorizontalAlign="Center"
						Position="TopAndBottom" Wrap="False" Mode="NumericPages"></PagerStyle>
				</asp:datagrid></td>
		</tr>
	</TABLE>
	<br>
	<asp:label id="Lblok" runat="server" Font-Bold="True" Height="14px" Font-Size="10pt" Width="608px"
		ForeColor="#C00000" Font-Names="Tahoma"></asp:label><br>
	<SCRIPT src="/ccapps/web/js/buttonset.js"></SCRIPT>
	<script>begin();geri("geri","geri","history.back();");end();</script>
</form>
